package com.ruleengine.worker.runner.chain;

import java.util.Set;

import com.ruleengine.worker.model.Chain;

/**
 * @author lianghanwei on 2024/3/10
 */
public interface ChainRunnerManager<T extends ChainRunner> {

    void add(Chain chain);

    T get(String uid);

    T getOrAddIfAbsent(Chain chain);

    boolean exist(String uid);

    void remove(String uid);

    void update(String uid, Chain newChain);

    int size();

    Set<String> uidSet();

    void clear();

    void close();

}
